import { MockMethod } from 'vite-plugin-mock'
import { resultError, resultSuccess, getRequestToken, requestParams } from '../_util'

export default [
	{
		url: '/user/info',
		method: 'post',
		response: (request: requestParams) => {
			const info = {
				author: 'pzy小燕子',
				avatar: 'https://avatars.githubusercontent.com/u/39397772?s=60&v=4',
				projectAddress: 'https://github.com/ynzy/vue3-ts-wx-h5-template',
				demoUrl: 'https://vue3-ts-wx-h5-template.vercel.app/',
				demoCodeUrl: 'https://files.catbox.moe/lxle3w.png'
			}
			return resultSuccess(info)
		}
	}
] as MockMethod[]